package com.wfh.aiagent.rag;

// 注释掉阿里云DashScope相关的导入，因为已经切换到DeepSeek
// import com.alibaba.cloud.ai.dashscope.api.DashScopeApi;
// import com.alibaba.cloud.ai.dashscope.rag.DashScopeDocumentRetriever;
// import com.alibaba.cloud.ai.dashscope.rag.DashScopeDocumentRetrieverOptions;
import lombok.extern.slf4j.Slf4j;
import org.springframework.ai.chat.client.advisor.api.Advisor;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;

/**
 * @Author FengHuan Wang
 * @Date 2025/5/26 10:57
 * @Version 1.0
 * 注意：此配置已被禁用，因为DeepSeek不支持阿里云的云端RAG服务
 */
@Configuration
@Slf4j
public class ProgramingAppRagCloudAdvisorConfig {

    // @Value("${spring.ai.openai.api-key}")
    // private String apiKey;

    // 已完全禁用阿里云RAG云服务Bean，因为DeepSeek不支持
    // 如需使用，请取消注释并配置阿里云DashScope
    /*
    @Bean
    public Advisor programingRagCloudAdvisor(){
        // 原阿里云DashScope配置
        DashScopeApi dashScopeApi = new DashScopeApi(apiKey);
        final String KNOWLEDGE_INDEX = "ProgramingApp";
        DocumentRetriever documentRetriever = new DashScopeDocumentRetriever(dashScopeApi,
                DashScopeDocumentRetrieverOptions.builder()
                        .withIndexName(KNOWLEDGE_INDEX)
                        .build());
        return RetrievalAugmentationAdvisor.builder()
                .documentRetriever(documentRetriever)
                .build();
    }
    */
}
